<template>
	<view class="p-20">
		<view class="bg-white p-30 border-radius">
			<view class="form-item mb-40">
				<view class="font-bold font-28">工作性质</view>
				<view class="mt-20">
					<uni-data-checkbox v-model="form.job_nature" :localdata="job_nature" />
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">工作城市</view>
				<view class="mt-20">
					<uni-data-select
					      v-model="form.city"
					      :localdata="city_enum"
					      @change="change"
					    ></uni-data-select>
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">职业名称</view>
				<view class="mt-20">
					<uni-easyinput v-model="form.name" placeholder="请输入职业名称" />
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">职业类别</view>
				<view class="mt-20">
					<uni-data-select
					      v-model="form.postion"
					      :localdata="range"
					      @change="change"
					    ></uni-data-select>
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">职业描述</view>
				<view class="mt-20">
					<uni-easyinput v-model="form.info" placeholder="请输入职业描述" />
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">学历要求</view>
				<view class="mt-20">
					<uni-data-select
					      v-model="form.education"
					      :localdata="education_enum"
					      @change="change"
					    ></uni-data-select>
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">经验要求</view>
				<view class="mt-20">
					<uni-data-select
					      v-model="form.experience"
					      :localdata="experience_enum"
					      @change="change"
					    ></uni-data-select>
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">最低薪资</view>
				<view class="mt-20">
					<uni-easyinput v-model="form.pay_low" placeholder="请输入最低薪资" />
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">最高薪资</view>
				<view class="mt-20">
					<uni-easyinput v-model="form.pay_high" placeholder="请输入最高薪资" />
				</view>
			</view>
			<view class="form-item mb-40">
				<view class="font-bold font-28">招聘人数</view>
				<view class="mt-20">
					<uni-easyinput v-model="form.people_num" placeholder="请输入招聘人数" />
				</view>
			</view>
		</view>
		
		<view class="bottom-view">
			<view class="bottom-btn font-white bg-g" @click="submit">发布职位</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				job_nature: [{
					text: '全职',
					value: 0
				}, {
					text: '兼职',
					value: 1
				}, {
					text: '实习',
					value: 2
				}, {
					text: '校园',
					value: 3
				}],
				education_enum: [
					{
						text: '初中及以下',
						value: '初中及以下'
					},{
						text: '中专/中技',
						value: '中专/中技'
					},{
						text: '高中',
						value: '高中'
					},{
						text: '大专',
						value: '大专'
					},{
						text: '本科',
						value: '本科'
					},{
						text: '硕士',
						value: '硕士'
					},{
						text: '博士',
						value: '博士'
					}
				],
				experience_enum: [
					{
						text: '实习',
						value: '实习'
					},{
						text: '1年以内',
						value: '1年以内'
					},{
						text: '1-3年',
						value: '1-3年'
					},{
						text: '3-5年',
						value: '3-5年'
					},{
						text: '5年以上',
						value: '5年以上'
					}
				],
				city_enum: [
					{
						text: '东营市',
						value: '东营市'
					},{
						text: '河口区',
						value: '河口区'
					},{
						text: '垦利区',
						value: '垦利区'
					},{
						text: '广饶县',
						value: '广饶县'
					},{
						text: '利津县',
						value: '利津县'
					}
				],
				form: {
					status: 1
				}
			};
		},
		onLoad() {
			
		},
		methods: {
			submit() {
				const _this = this
				this.$tips.showModal('是否提交职位信息？', () => {
					_this.$tips.showConfirmModal('提交成功，请等待审核', () => {
						uni.navigateBack()
					})
				})
			}
		}
	}
</script>

<style lang="less">
	page{
		background-color: #f6f6f6;
		padding-bottom: 200rpx;
	}
	.bottom-view {
		width: 100vw;
		padding: 40rpx 0;
		background-color: #fff;
		position: fixed;
		bottom: 0;
		left: 0;
		z-index: 99999;
		border-top: 1px solid #efefef;
		.bottom-btn {
			width: 80vw;
			margin: auto;
			text-align: center;
			border-radius: 50rpx;
			padding: 20rpx 0;
		}
	}
</style>
